home *** CD-ROM | disk | FTP | other *** search
- Path: crchh327.rich.bnr.ca!jobell
- From: jobell@bnr.ca (Bret Bieghler)
- Newsgroups: comp.lang.c++
- Subject: Re: why is dat ?
- Date: 30 Jan 1996 16:46:22 GMT
- Organization: Bell-Northern Research Ltd.
- Message-ID: <4eli0u$ipc@crchh327.rich.bnr.ca>
- References: <310DCC58.798E@pergamon.isar.de>
- NNTP-Posting-Host: crchh524.rich.bnr.ca
-
- In article <310DCC58.798E@pergamon.isar.de>,
- Gerson Kurz <dekonstruktor@pergamon.isar.de> wrote:
- >hi guys, this is my first msg here so I don't know if this has
- >been answered 10^50 times before but here it goes:
- >
- >class A {};
- >class B : public A {};
- >
- >B* pointer_to_B;
- >A** pointer_to_pointer_to_A = &pointer_to_B;
- >
- >will result in an error (using MSVC40, wl4) headed "improved
- >ansi comp."
- >
- >why is dat ? (boogie down productions, 1989)
-
- A** is not &B, it is a pointer to any A*.
-
- pointers to pointers are also known as handles, commonly used
- for avoiding losing your data during heap compactions.
-
- JB
-
- --
- Joseph A. Bell (NOT Bret Bieghler) jobell@bnr.ca
- Northern Telecom / Bell-Northern Research
- "What? Evacuate now, in our moment of triumph? Surely you overestimate their chances."
-